package com.mikeli.javacourse.lesson3.homework.gateway.filter.impl;

import com.mikeli.javacourse.lesson3.homework.gateway.filter.HttpRequestFilter;
import io.netty.channel.ChannelHandlerContext;
import io.netty.handler.codec.http.FullHttpRequest;
import io.netty.handler.codec.http.HttpHeaders;

public class HttpRequestHeaderFilter implements HttpRequestFilter {
    /**
     * 增加 header 信息
     * @param fullRequest
     * @param ctx
     */
    @Override
    public void filter(FullHttpRequest fullRequest, ChannelHandlerContext ctx) {
        HttpHeaders headers = fullRequest.headers();
        headers.add("xjava","hello netty");
    }
}
